package cn.edu.hunau.service;


import cn.edu.hunau.exception.DaoException;
import cn.edu.hunau.exception.UserNameExistsException;
import cn.edu.hunau.exception.UsernameOrPwdErrorException;
import cn.edu.hunau.pojo.User;

/**
 * 处理用户的业务逻辑
 * @Author 苏佳
 * @Date 2022 09 18 09 29
 **/
public interface UserService {

    User regist(String username, String pwd) throws DaoException;

    User loginByUsername(String username,String pwd) throws DaoException, UsernameOrPwdErrorException;
    User loginByTel(String tel,String pwd) throws DaoException;

    boolean checkUserName(String username) throws UserNameExistsException;

    boolean updatePwdByUid(String oldPwd,String newPwd,Integer uid)throws DaoException;

    boolean bandingTel(String tel,Integer uid)throws DaoException;

    User findMyInforByUid(Integer uid)throws DaoException;
}
